Skip to content

feat: add C implementation for math/base/sepcial/gammaincinv#8300

Closed
rajanarahul93 wants to merge 6 commits intostdlib-js:developfrom
rajanarahul93:feat-gammaincinv-c-impl-3355
Closed

feat: add C implementation for math/base/sepcial/gammaincinv#8300
rajanarahul93 wants to merge 6 commits intostdlib-js:developfrom
rajanarahul93:feat-gammaincinv-c-impl-3355

Conversation

@rajanarahul93
Copy link
Copy Markdown
Contributor

@rajanarahul93 rajanarahul93 commented Oct 26, 2025

Progresses #3677.

Description

What is the purpose of this pull request?

This pull request:

  • Adds a C implementation for @stdlib/math/base/special/gammaincinv, including a Node-API addon, C examples, C benchmarks, native JS tests, and native JS benchmarks, fulfilling the requirements outlined in the related RFC. This implementation is a necessary prerequisite for adding a C implementation to @stdlib/stats/base/dists/invgamma/quantile.

Related Issues

Does this pull request have any related issues?

This pull request has the following related issues:

Questions

Any questions for reviewers of this pull request?

No.

Other

Any other information relevant to this pull request? This may include screenshots, references, and/or implementation notes.

No.

Checklist

Please ensure the following tasks are completed before submitting this pull request.

AI Assistance

When authoring the changes proposed in this PR, did you use any kind of AI assistance?

  • Yes
  • No

If you answered "yes" above, how did you use AI assistance?

  • Code generation (e.g., when writing an implementation or fixing a bug)
  • Test/benchmark generation
  • Documentation (including examples)
  • Research and understanding

Disclosure

If you answered "yes" to using AI assistance, please provide a short disclosure indicating how you used AI assistance. This helps reviewers determine how much scrutiny to apply when reviewing your contribution. Example disclosures: "This PR was written primarily by Claude Code." or "I consulted ChatGPT to understand the codebase, but the proposed changes were fully authored manually by myself.".

Assisted by an AI (Gemini) to generate the C code translation, Node-API boilerplate, Makefiles, tests, benchmarks, documentation updates, and Git/build commands based on the existing JavaScript implementation and stdlib conventions. Local build verification was problematic due to environment issues, but the code structure follows project patterns.


@stdlib-js/reviewers

@stdlib-bot stdlib-bot added Math Issue or pull request specific to math functionality. Needs Review A pull request which needs code review. Good First PR A pull request resolving a Good First Issue. labels Oct 26, 2025
@stdlib-bot
Copy link
Copy Markdown
Contributor

⚠️ Tracking Issue Closure Warning ⚠️

I noticed your PR description contains closing keywords ("Resolves", "Closes", or "Fixes") referencing a "Tracking Issue".

Why this matters:
Tracking issues should typically remain open until all related sub-issues are completed. GitHub automatically closes issues with such closing keywords when the PR is merged. For more information, see GitHub's documentation on using keywords in issues and pull requests.

Required action:
Use "Progresses" instead to reference the tracking issue without automatically closing it.

Thank you for your contribution to the project!

@gunjjoshi
Copy link
Copy Markdown
Member

gunjjoshi commented Oct 27, 2025

@rajanarahul93 Thank you for working on this. You'll need to spend some time in getting familiar with the packages in math/base/special/*. The current changes in this PR do not seem to be close to what is required to add the C implementation of a package. I would suggest to refer to old related PRs and trying it out yourself.

@gunjjoshi gunjjoshi added Needs Changes Pull request which needs changes before being merged. and removed Needs Review A pull request which needs code review. labels Oct 27, 2025
@gunjjoshi gunjjoshi changed the title feat(@stdlib/math/base/special/gammaincinv): add C implementation feat: add C implementation for math/base/sepcial/gammaincinv Oct 27, 2025
@rajanarahul93
Copy link
Copy Markdown
Contributor Author

Thanks for the feedback, @gunjjoshi. I’ll go through similar past PRs and existing math/base/special packages to better understand the structure and requirements, then update this implementation accordingly.

@kgryte kgryte added the autoclose: Project Conventions Pull request which should be auto-closed due to not following project conventions. label Dec 3, 2025
@stdlib-bot
Copy link
Copy Markdown
Contributor

Thank you for working on this pull request. However, we cannot accept your contribution as this pull request does not follow project conventions.

We place a high value on consistency throughout the stdlib codebase, and this pull request was found to significantly deviate from stdlib conventions. We encourage you to closely examine other packages in stdlib and attempt to emulate the practices and conventions found therein.

  • If you are attempting to contribute a new package, sometimes the best approach is to simply copy the contents of an existing package and then modify the minimum amount necessary to implement the feature (e.g., changing descriptions, parameter names, and implementation).
  • If you are contributing tests, find a package implementing a similar feature and emulate the tests of that package.
  • If you are updating documentation, examine several similar packages and emulate the content, style, and prose of those packages.

In short, the more effort you put in to ensure that your contribution looks and feels like stdlib—including variables names, bracket spacing, line breaks, etc—the more likely that your contribution will be reviewed and ultimately accepted. We encourage you to closely study the codebase before continuing to work on this pull request.

Thank you again for your interest in stdlib, and we look forward to reviewing your future contributions.

@stdlib-bot stdlib-bot closed this Dec 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

autoclose: Project Conventions Pull request which should be auto-closed due to not following project conventions. Good First PR A pull request resolving a Good First Issue. Math Issue or pull request specific to math functionality. Needs Changes Pull request which needs changes before being merged.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants